﻿using System.Collections;
using System.Collections.Generic;
using UnityEngine;

///<summary>
///
///</summary>
public class PoPBoomComponent : MonoBehaviour
{
	public GameObject pop;
    
	public void Retarder()
	{
		switch (pop.GetComponent<PoPPropComponent>().GetPropIcon())
		{
			case 0://减速
				AppFacde.Instance.SendNotification(GameEvents.RETARDER);
				Debug.Log("减速");
				break;
			case (PropNum)1://闪电
				AppFacde.Instance.SendNotification(GameEvents.LIGHTNING);
				Debug.Log("闪电");
				break;
			case (PropNum)2://清除一个离地面最近的
				AppFacde.Instance.SendNotification(GameEvents.CLEAR_ONE);
				Debug.Log("一个");
				break;
			case (PropNum)3://清除一种
				AppFacde.Instance.SendNotification(GameEvents.CLEAR_RANDOM_BALLOON);
				Debug.Log("清除一种汽泡");
				break;
			case (PropNum)4://加速落下
				AppFacde.Instance.SendNotification(GameEvents.SPEED_UP);
				Debug.Log("加速");
				break;
		}
	}
}
